from django.db import models
from django.contrib.auth.models import User

class Vocabulary(models.Model):
    user = models.ForeignKey(User, unique=False)
    word = models.CharField(max_length=50, unique=True)
    reg_date = models.DateTimeField('date published', auto_now=True)

class Senses(models.Model):
    user = models.ForeignKey(User, unique=False)
    word = models.ForeignKey(Vocabulary, unique=False)
    meaning = models.CharField(max_length=200, unique=True)
    reg_date = models.DateTimeField('date published', auto_now=True)

class ExampleSentences(models.Model):
    user = models.ForeignKey(User, unique=False)
    word = models.ForeignKey(Vocabulary, unique=False)
    setence = models.CharField(max_length=500, unique=True)
    reg_date = models.DateTimeField('date published', auto_now=True)


